import {customeStruct} from '../utils';
const itf = customeStruct.interface;
export const InitData = itf({
    payload: itf({
        isDealerUser: 'boolean',
        brands: [itf({
            id: 'string',
            name: 'string'
        })],
    })
});
export const List = itf({
    payload: itf({
        content: [itf(Object.assign({
            id: 'string',
            code: 'string',
            dealerCode: 'string',
            dealerName: 'string',
            status: 'number',
            productCategoryCode: 'string? | null',
            productCategoryName: 'string? | null',
            faultPartCode: 'string? | null',
            problemSeverity: 'number',
            creatorTime: 'datetime? | null',
            submitTime: 'datetime? | null',
            rowVersion: 'string',
        }))],
        totalElements: 'number',
    })
});
export const Detail = itf({
    payload: itf(Object.assign({
        id: 'string',
        code: 'string',
        branchCode: 'string',
        branchName: 'string',
        brandId: 'string',
        brandCode: 'string? | null',
        brandName: 'string? | null',
        dealerId: 'string',
        dealerCode: 'string? | null',
        dealerName: 'string? | null',
        serviceEngineer: 'string? | null',
        qualityEngineer: 'string? | null',
        status: 'number',
        productCategoryId: 'string? | null',
        productCategoryCode: 'string? | null',
        productCategoryName: 'string? | null',
        vehicleNature: 'number? | null',
        frequency: 'number? | null',
        region: 'string? | null',
        country: 'string? | null',
        faultPartCode: 'string? | null',
        customerComplainQty: 'number? | null',
        outRescueQty: 'number? | null',
        specialCompensateQty: 'number? | null',
        carReturnQty: 'number? | null',
        marketValueFactor: 'number? | null',
        warranty: 'number? | null',
        importInfo: 'number? | null',
        causePartId: 'string? | null',
        causePartCode: 'string? | null',
        causePartName: 'string? | null',
        faultyPartBatch: 'string? | null',
        softwareVersionNumber: 'string? | null',
        failureRatio: 'number? | null',
        iPTV: 'number? | null',
        occurCondition: 'number? | null',
        issueRoadConditions: 'string? | null',
        issueWorkConditions: 'string? | null',
        driveHabits: 'string? | null',
        useEnvironment: 'string? | null',
        problemDescribe: 'string? | null',
        servicePropose: 'string? | null',
        factoryAdvice: 'string? | null',
        problemSeverity: 'number? | null',
        replyForm: 'number? | null',
        creatorTime: 'datetime? | null',
        creatorName: 'string? | null',
        modifierName: 'string? | null',
        modifyTime: 'datetime? | null',
        submitterName: 'string? | null',
        submitTime: 'datetime? | null',
        abandonerName: 'string? | null',
        abandonTime: 'datetime? | null',
        rowVersion: 'string',
        details: [
            itf({
                id: 'string',
                vin: 'string',
                productCategoryCode: 'string? | null',
                productCategoryName: 'string? | null',
                engineCode: 'string? | null',
                transmissionSn: 'string? | null',
                productionDate: 'datetime? | null',
                saleDate: 'datetime? | null',
                faultDescription: 'string? | null',
                inspectionProcess: 'string? | null',
                dealResult: 'string? | null',
                partCode: 'string? | null',
                partName: 'string? | null',
                supplierCode: 'string? | null',
                repairDate: 'datetime? | null',
                mileage: 'number? | null',
                claimPrice: 'number? | null',
                subDealerCode: 'string? | null',
                subDealerName: 'string? | null',
            })
        ],
        confirmResult: [
            itf({
                id: 'string',
                confirmorName: 'string? | null',
                confirmTime: 'datetime? | null',
                confirmComment: 'string? | null',
                approveResult: 'number? | null',
            })
        ],
        improveResult: [
            itf({
                id: 'string',
                registerName: 'string? | null',
                registerTime: 'datetime? | null',
                improveSuggestion: 'string? | null',
            })
        ],
    }))
});
export const ProductCategoryList = itf({
    payload: itf({
        content: [
            itf({
                id: 'string',
                code: 'string',
                name: 'string',
                remark: 'string? | null',
            })
        ]
    })
});
export const PartList = itf({
    payload: itf({
        content: [
            itf({
                id: 'string',
                code: 'string',
                name: 'string',
                productCategoryCode: 'string? | null',
                unit: 'string? | null',
                minPackSize: 'number? | null',
                price: 'number? | null',
            })
        ]
    })
});
export const VehicleSoldList = itf({
    payload: itf({
        content: [
            itf({
                id: 'string',
                vin: 'string',
                vehicleProperty: 'number? | null',
                productCategoryCode: 'string? | null',
                productCategoryName: 'string? | null',
                mileage: 'number? | null',
                licensePlate: 'string? | null',
                invoiceDate: 'datetime? | null',
                engineCode: 'string? | null',
                transmissionSn: 'string? | null',
                productionDate: 'datetime? | null',
                saleDate: 'datetime? | null',
                status: 'number',
                salesDealerCode: 'string? | null',
                salesDealerName: 'string? | null',
                customerSoldCode: 'string? | null',
                customerSoldName: 'string? | null',
                cellPhoneNumber: 'string? | null',
                address: 'string? | null',
            })
        ]
    })
});
